package com.smartleanx.module.hrm.util.esign.constant;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * 个人授权配置项
 *
 * @author yanglihao
 */
public class PsnAuthScope {

    // 个人授权通用
    public static final List<String> PSN_COMMON_SCOPE = new ArrayList<String>() {
        {
            add(GET_PSN_IDENTITY_INFO);
            add(PSN_INITIATE_SIGN);
            add(MANAGE_PSN_RESOURCE);
        }
    };

    // 授权允许获取个人用户的账号信息（姓名、手机号/邮箱、证件号等）
    public static final String GET_PSN_IDENTITY_INFO = "get_psn_identity_info";

    // 授权允许代表个人用户发起合同签署以及查询合同签署详情
    public static final String PSN_INITIATE_SIGN = "psn_initiate_sign";

    // 授权允许获取个人用户的印章等资源的管理权限
    public static final String MANAGE_PSN_RESOURCE = "manage_psn_resource";

    // 授权允许个人合同文件存储到平台应用的本地服务器
    public static final String PSN_SIGN_FILE_STORAGE = "psn_sign_file_storage";

    // 权限标识转中文
    public static final Map<String, String> PSN_AUTH_SCOPE_NAME = new HashMap<String, String>() {
        {
            put("get_psn_identity_info", "授权允许获取个人用户的账号信息（姓名、手机号/邮箱、证件号等）");
            put("psn_initiate_sign", "授权允许代表个人用户发起合同签署以及查询合同签署详情");
            put("manage_psn_resource", "授权允许获取个人用户的印章等资源的管理权限");
            put("psn_sign_file_storage", "授权允许个人合同文件存储到平台应用的本地服务器");
        }
    };
}
